package com.numberone.master.modules.oa.service;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.numberone.master.common.persistence.Page;
import com.numberone.master.common.service.CrudService;
import com.numberone.master.modules.oa.dao.DelayedDao;
import com.numberone.master.modules.oa.entity.Delayed;


@Service
@Transactional(readOnly = true)
public class DelayedService extends CrudService<DelayedDao, Delayed>{
	
	public Delayed get(String id) {
		return dao.get(id);
	}
	
	public Page<Delayed> findList(Page<Delayed> page,Delayed delayed) {
		delayed.setPage(page);
		page.setList(dao.findList(delayed));
		return page;
	}
	
	@Transactional(readOnly = false)
	public void insert(Delayed delayed) {
		dao.insert(delayed);
	}

	@Transactional(readOnly = false)
	public void update(Delayed delayed) {
		dao.update(delayed);
	}

}
